class Mythread extends Thread {
    @Override
    public void run() {
        while(true){
            System.out.println("hello thread!");
        }
    }
}

public class Text1 {
    public static void main(String[] args) {
        Mythread t = new Mythread();
        t.start();

        while (true){
            System.out.println(" hello main!");
        }
    }
}
